package collection;

import java.util.ArrayList;
import java.util.Collection;

public class CollectionDemo {
    public static void main(String[] args) {
        Collection o1=new ArrayList();
        o1.add(new Point(1,1));
        o1.add(new Point(2,2));
        o1.add(new Point(4,4));
        o1.add(new Point(5,5));
        o1.add(new Point(6,6));
        o1.add(new Point(7,7));
        System.out.println(o1);
        Point o2=new Point(5,5);
        boolean con= o1.contains(o2);
        System.out.println(con);
        o1.remove(o2);
        System.out.println(o1);
        Point pp=new Point(6,6);
        o1.add(pp);
        pp.setX(200);
        System.out.println(o1);















//        Collection o1=new ArrayList();
//        o1.add("李信德");
//        o1.add("姜志可");
//        o1.add("耿梦蕾");
//        o1.add("杨博远");
//        System.out.println(o1);
//        System.out.println(o1.isEmpty());
//        System.out.println(o1.size());
    }
}
